package loupan_db

import (
	database "hft/Database"
	"time"
)

// 平台
type Platform struct {
	ID         int       `json:"id" gorm:"primaryKey;autoIncrement"`
	Sort       int       `json:"sort"` //排序值
	LouPanID   int       `json:"lou_pan_id" gorm:"uniqueIndex:idx_loupan_id_name"`
	Name       string    `json:"name" gorm:"uniqueIndex:idx_loupan_id_name"` //平台名称
	Settlement string    `json:"settlement"  gorm:"type:longtext"`           //结算
	Commission string    `json:"commission"  gorm:"type:longtext"`           //佣金
	JudgeRules string    `json:"judge_rules" gorm:"type:longtext"`           //判客规则
	UpdateTime time.Time `json:"update_time" gorm:"autoUpdateTime"`
}

func (Platform) TableName() string {
	return database.TableNameFormat("platform")
}
